import axios from 'axios';
import { req,getReq } from './axiosFun';

/**
 * 用户管理
 */
//获取用户总数量
export const loadUsersSize = (params) => {return getReq("http://circlepro.cn/Backend/Read/LoadUsersSize",params)}
// //拒绝用户获得主体资格
// export const userDelete = (params) => {return req("get","/api/CircleBreaker/User/GetInfo",params)}
// //同意用户获得主体资格
// export const userSave = (params) => {return req("")}
//获取单个用户详细信息
export const getUserById = (params) => {return getReq("http://circlepro.cn/Backend/Read/GetUserById",params)}
//获取一页的用户
export const loadUsersByPage = (params) => {return getReq("http://circlepro.cn/Backend/Read/LoadUsersByPage",params)}
//修改用户登记权限
export const authorize = (params) => {return req("http://circlepro.cn/Backend/authorize",params)}
//邀请码可视化
export const loadApplyKeys = (params) => {return getReq("http://circlepro.cn/Backend/Read/LoadApplyKeys",params)}
//用户邀请码管理
export const disableKey = (params) =>{return getReq("http://circlepro.cn/Backend/User/DisableKey",params)}



/** 
 * 主体资格管理
*/
//获取当前正在处理的工作
export const userWorkNow = (params) => {return getReq("http://circlepro.cn/Backend/User/WorkNow",params)}
//获得一个工作
export const userGetWork = (params) => {return getReq( "http://circlepro.cn/Backend/User/GetWork",params)}
//获取一个验证码（用于主体资格申请）
export const getKey = (params) => {return getReq("http://circlepro.cn/Backend/User/GetKey",params)}
//查看工作记录
export const userLoadWorks = (params) => {return getReq("http://circlepro.cn/Backend/User/LoadWorks",params)}
//获取申请列表
export const  userGetApplyList = (params) => {return getReq("http://circlepro.cn/Backend/User/GetApplyList",params)}
//返回申请的结果
export const  userApplyRes = (params) => {return getReq("http://circlepro.cn/Backend/User/ApplyRes",params)}
//获取用户参与的活动
export const  getParticipatedAct = (params) => {return getReq("http://circlepro.cn/Backend/Read/GetParticipateAct",params)}
//获取用户发起的活动
export const  getOriginatedAct = (params) => {return getReq("http://circlepro.cn/Backend/Read/GetOriginatedAct",params)}
//获得所有邀请码
export const  loadApplyCode = (params) => {return getReq("http://circlepro.cn/Backend/Read/LoadApplyCode",params)}


/** 
 * 活动管理
*/
//获取总活动数量
export const  loadActSize = (params) => {return getReq("http://circlepro.cn/Backend/Read/LoadActSize",params)}
//获得活动详细信息
export const loadAct = (params) => {return getReq("http://circlepro.cn/Backend/Read/LoadAct",params)}
//获得一页的活动
export const  loadActByPage = (params) => {return getReq("http://circlepro.cn/Backend/Read/LoadActByPage",params)}
//获取全部的参与者
export const  loadActPartic = (params) => {return getReq("http://circlepro.cn/Backend/Read/LoadActPartic",params)}
//撤销活动
export const cancelAct = (params) => {return getReq( "http://circlepro.cn/Backend/Content/CancelAct",params)}
//返回申请的结果 1为通过 0为不通过
export const actApplyRes = (params) => {return getReq( "http://circlepro.cn/Backend/Act/ApplyRes",params)}
//获得当前正在处理的工作
export const actWorkNow = (params) => {return getReq( "http://circlepro.cn/Backend/Act/WorkNow",params)}
//获得一个工作
export const actGetWork = (params) => {return getReq( "http://circlepro.cn/Backend/Act/GetWork",params)}
//活动工作记录
export const actLoadWorks = (params) => {return getReq( "http://circlepro.cn/Backend/Act/LoadWorks",params)}
//获取申请列表
export const actGetApplyList = (params) => {return getReq("http://circlepro.cn/Backend/Act/GetApplyList",params)}
//修改活动tag信息
export const editActTag = (params) =>{return req("http://circlepro.cn/Backend/Act/EditActTag",params)}
//获取所有tag信息
export const loadAllTags = (params) =>{return req("http://circlepro.cn/Backend/Read/LoadAllTags",params)}
//新建Tag
export const newTagI = (params) =>{return req("http://circlepro.cn/Backend/Content/NewTag",params)}
//新建活动
export const originateAct = (params) =>{return getReq("http://circlepro.cn/Backend/Content/OriginateAct",params)}
//用户新建活动
export const userOriginateAct = (params,Token) =>{return getReqT("http://circlepro.cn/CircleBreaker/Activity/OriginateAct",params,Token)}
//上传图片
export const uploadPic = (params) =>{return req("http://circlepro.cn/Backend/Content/UploadPic",params)}
/** 
 * 轮播图管理
*/
//获取轮播图上的活动列表
export const  loadBanner = (params) => {return getReq("http://circlepro.cn/Backend/Content/LoadBanner",params)}
//轮播图修改
export const  editAct = (params) => {return getReq("http://circlepro.cn/Backend/Content/EditAct",params)}
